import { IFeidaoAiBrowserComponent } from '@dfeidao/atom-web/interfaces';
import nodejs from '@dfeidao/atom-web/msg/nodejs';
import p001 from './p001';
import render from '@dfeidao/atom-web/render/render';
import p002 from './p002';
import set from '@dfeidao/atom-web/local/set';
import set1 from '@dfeidao/atom-web/global/set';
export default async function a001(fd: IFeidaoAiBrowserComponent) {
	// todo


	const res = await nodejs<{ data: [{ post_package: string, _id: string }], x: number; }>('GuoKai/zj-000003/s001', {
		page_no: 1
	});
	const post_package = res.data[0].post_package
	set1('post_package1', res.data[0].post_package);
	set(fd, '_id1', res.data[0]._id)
	const res1 = await nodejs<{ data: [], x: number; }>('GuoKai/zj-000003/s002', {
		page_no: 1,
		post_package: post_package,

	});
	console.log(res1);

	render(fd, res, p001, 'p001', 'inner');
	render(fd, res1, p002, 'p002', 'inner');
}
